1. Field of the Invention
The invention is in the field of data processing and more specifically in the field of processing data generated using multi-gain detectors.
2. Background Art
Detectors are typically characterized by at least a dynamic range and a precision. Dynamic range relates to the largest and smallest signal that a detector can correctly measure. Precision relates to the number of separately discernable signal levels or values within the dynamic range. In some instances precision is expressed as a number of bits. For example, a detector with a precision of 8-bits may be configured to report a measurement as being within one of 28 (256) possible values. Alternatively, precision may be expressed as an absolute amount (e.g., 1 mV) reflecting the difference between separately discernable signal levels.
Detectors generate raw data that may be subsequently corrected, to “corrected data,” using a gain factor and an offset. For example, a corrected data value may be calculated using the equation Y=m(X−b), where Y is the corrected value, X is the raw data value representative of detected signal intensity, m is the gain factor (assumed in this example to be linear), and b is the offset. Thus, the gain factor and offset determine the magnitude of corrected data output for a given input signal and may be selected by a designer or user of a detector in anticipation of the type and size of expected input signals. An 8-bit voltage detector with an offset (b) of 100 mV and a gain factor (m) of 1 mV/raw-data-unit may be configured to measure voltages between 100 mV (where X=0) and 355 mV (where X=255). In this example, raw data output of 100 units (X=100) corresponds to 0 mV and an output of 150 raw-data-units (X=150) corresponds to 50 mV.
In some instances arrays of detectors are used to generate two-dimensional arrays (images) of raw data. These arrays of raw data may be corrected, using a corresponding array of gain factors called a “gain image” and an array of offsets called an “offset image,” to generate an array of corrected data. Each gain image and offset image includes one gain factor and one offset, respectively, for each detector in the array of detectors. These gain factors and offsets are determined during calibration processes prior to data acquisition. Gain images and offset images enable the use of well known efficient calculation algorithms during the correction process.
Corrected data may subsequently be normalized to “viewable” data for presentation to a user or for further processing. For example, the corrected data may be mapped to a range of colors or gray scale and the user may be shown an image representative of the data using these colors. In some instances corrected data is mapped to a standard RGB scale used by many computer monitors. The normalization of corrected data to viewable data is typically performed using a simple lookup table in a step separate from the correction of raw data to corrected data.
Detectors may be characterized as either multi-gain or non-multi-gain detectors. Multi-gain detectors include a variable dynamic range. For example in a dual-gain detector a first “low” dynamic range may be used to measure lower intensity signals and a second “high” dynamic range may be used to measure higher intensity signals. The two dynamic ranges may differ in their offset and/or their gain factor. There are at least two known approaches to generating multi-gain data using a multi-gain detector: Dual Read Sampling (DRS) and Dynamic Gain Switching (DGS).
In the Dual Read Sampling approach, a dual-gain detector is used to perform two back-to-back measurements at two different dynamic ranges. Two raw scalar values are generated from the detector, one corresponding to the first dynamic range and one corresponding to the second dynamic range. There is a short delay between the time of the first measurement and the second measurement.
In the Dynamic Gain Switching approach, the dynamic range of a dual-gain detector is changed during a measurement. This change is dynamically responsive to the signal detected. Typically, a measurement will begin using a first (low) dynamic range having a first gain factor, and as the measured value approaches the maximum measurable value within the first dynamic range, the gain of the detector is changed to a second, smaller, gain factor. This results in a second (high) dynamic range with the same relative precision but a less precise absolute precision. The first dynamic range is preferred for measurement of the low intensity signals because the absolute precision of the first dynamic range is more precise than the absolute precision of the second dynamic range. The data resulting from a Dynamic Gain Switching detector includes a raw scalar value representative of the magnitude of the detected signal and one or more gain flags indicating which dynamic range was used to generate the raw data value.
An advantage of a multi-gain detector is that the offset and gain factors (e.g., the dynamic range) can be dynamically changed during data acquisition in response to received input signals. Thus, the available precision of the detector may be used more optimally than in a single-gain detector. By designing two different dynamic ranges into a dual-gain detector two different ranges in input signal may be mapped to a single output range. Mapping various input ranges into a single output range is often an advantage. For example, a dual-gain detector may have a fixed output range between 0 and 255 (e.g., 8-bits) and input ranges of 0 to 100 and 0 to 500 units of signal intensity. By mapping both of the input ranges to the 8-bit output, all subsequent data processing, manipulation and visualization can be based on 8-bit data. In this way, design, engineering, cost, and other factors that limit the output range to a fixed maximum do not directly result in corresponding limits to the input ranges.
When using an array of dual-gain detectors to detect an image, some detectors within the array may use a first dynamic range while other detectors within the array may use a second dynamic range. The dynamic range that each particular detector uses is dependent on the particular signals received by that detector during each data acquisition. This signal dependent determination of dynamic range can be a problem in subsequent processing of the resulting data because the subsequent processing is dependent on which dynamic range was used to generate each data value. For example, because different dynamic ranges are associated with different gain factors and offsets, each dual-gain detector is associated with two pairs of gain factor and offset values. As a consequence, the single gain image and single offset image of the prior art are no longer sufficient for performing gain and offset corrections to an array of raw data because these images only include one gain factor and offset per detector. Therefore, in the prior art, the advantages of using a gain image and an offset image have been lost when processing dual-gain data. Instead, the correction of dual-gain data has been performed using single pairs of factor and offset values.
Following correction for gain and offset, dual-gain data is typically still in a multi-gain form, wherein interpretation of each data value requires knowledge of which dynamic range was used to generate the data value. In these instances, a further step is required in order to convert the multi-gain data to non-multi-gain data. This conversion step is performed prior to the normalization step of generating viewable data for display to a user or for further manipulation.
For these and other reasons, prior art processing of multi-gain data typically requires three steps: 1) correction of raw multi-gain data using appropriate gain factors and offsets, 2) conversion of corrected multi-gain data to non-multi-gain data, and 3) normalization of the non-multi-gain data to a scale appropriate for display or further manipulation. It would be advantageous to minimize the amount of calculation and data manipulation required to perform these tasks, particularly when processing arrays of multi-gain data.